package com.oak.interviewdemo.config.shiro.jwt;

import org.apache.shiro.authc.AuthenticationToken;

/**
 * JwtToken
 *
 * @Author: guoxy
 * @Date: 2020/5/14 22:53
 */
public class JwtToken implements AuthenticationToken {

    private String token;

    public JwtToken(String jwt) {
        this.token = jwt;
    }

    /**
     * 类似是用户名
     *
     * @return
     */
    @Override
    public Object getPrincipal() {
        return token;
    }

    /**
     * 类似密码
     *
     * @return
     */
    @Override
    public Object getCredentials() {
        return token;
    }
    //返回的都是jwt
}